Hi,
As of March 31 I intend to start a rollout of 50% of Beta 138 to remove UA styles for h1 in article, aside, nav, section on desktop. We will monitor web compat reports to evaluate impact. If it goes well, the plan is to roll out to 5% of Release 138 and then increase to 50%, and if it goes well, increase to 100% and let the change ride the trains for all platforms.
Status in other browsers is that they are interested in following our lead (1, 2). Chromium has also deprecated this, which makes the issue surface for web developers in Chromium's console as well as impacting the score in Lighthouse.
Bug to remove: https://bugzilla.mozilla.org/show_bug.cgi?id=1885509
Spec issue: https://github.com/whatwg/html/issues/7867
Rollout for Beta: https://experimenter.services.mozilla.com/nimbus/remove-ua-styles-for-h1-headings/summary
Rollout for Release: https://experimenter.services.mozilla.com/nimbus/remove-ua-styles-for-h1-headings-release/summary
Pref: layout.css.h1-in-section-ua-styles.enabled (false means the UA styles are removed)
Compat analysis:
We have a warning in the devtools console since 136 when a page has a h1 in article, aside, nav, or section, and no author-origin font-size or margins specified. The pref has been false in Nightly since March 2024, with only one web compat issue reported (the site was fixed).
Rationale and context for this change:
Advice for web developers: https://developer.mozilla.org/en-US/docs/Web/HTML/Element/Heading_Elements#specifying_a_uniform_font_size_for_h1
cheers,
--